<?php

class autoLoader
{
    public static function load($class)
    {
//        var_dump($class);
        $path = __DIR__ . '/'.str_replace('\\', '/', $class) . '.php';

        try {
            include $path;
        } catch (\Exception $exception) {
            echo $exception->getMessage();
        }
    }
}

spl_autoload_register('autoLoader::load');


//echo __DIR__;
//echo PHP_EOL;
//echo basename(__DIR__);
//echo PHP_EOL;
//echo dirname(__DIR__);

